package cn.caplike.demo.repository.design.pattern.responsibilitychain;

class ConcreteHandlerB extends Handler {

    public ConcreteHandlerB(Handler next) {
        super(next);
    }

    @Override
    boolean handle(String message, Integer days) {
        if (days <= 15) {
            System.out.println("处理请求：" + message);
            System.out.println("请假天数：" + days);
            System.out.println("ConcreteHandlerB handled");
            return true;
        }

        return next().handle(message, days);
    }
}
